# Fastlane Integration

# Overview

Fastlane, an open-source platform, streamlines mobile app builds and deployments. Integrating the AppSealing CLI tool with Fastlane enhances your workflow by seamlessly adding security measures, ensuring a secure and efficient build process for your application.

# Prerequisites

Before integrating AppSealing CLI tool with Fastlane, ensure you have the following prerequisites:

  • Access to the Fastlane setup for your project.
  • Java Runtime Environment (JRE) installed on your system.
  • Download AppSealing CLI tool (sealing.jar) from web console

# Integration Steps

Follow these steps to integrate AppSealing CLI tool into your Fastlane workflow:

  1. Locate sealing.jar File: Place the sealing.jar in a location accessible from your Fastlane environment.

  2. Update Fastfile: Open your Fastfile located in the root directory of your project.

  3. Add a new lane: Add a new lane in your Fastfile to execute AppSealing CLI tool after building the APK or AAB file. Below is a sample lane definition:

lane :post_build_actions do
  # Execute AppSealing CLI tool
  sh "java -jar sealng.jar -config config.txt -srcapk TARGET.apk -sealedapk TARGET_SEALED.apk"
end

You can replace the path of sealing.jar, config.txt, TARGET.apk and TARGET_SEALED.apk to your actual path. To check the detail configuration of CLI Tool configuration, you can check (Run sealing.jar using configuration file)[/guide/5.%20CI%20CD%20Pipeline/2.%20Basic%20Configuration.html#run-sealing-jar-using-the-config-txt-file] page.

  1. Call the Lane: Invoke the newly defined lane from the command line after build APK/AAB:
fastlane post_build_actions
  1. Verify Output: AppSealing CLI tool will execute the specified post-build actions, add security, and download the sealed APK or AAB file to the specified location.
Last Updated: 11/19/2024, 6:55:37 AM